﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" 
CodeBehind="NewsTranslationPage.aspx.cs" Inherits="Nivdal.NewsTranslationPage" Theme="SkinFile" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadPlaceHolder" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
    <ContentTemplate>
        <div class="basic_element">
        <div class="red_title">
           <asp:Label ID="MessageLabel" runat="server" CssClass="white_title"></asp:Label>
        </div>
        <div class="padding5">
        
            <asp:FormView ID="NewsItemTranslationFormView" runat="server" DataSourceId="TranslateDataSource">
                <ItemTemplate>
                    <asp:Label ID="TranslateLabel" runat="server" SkinID="GridLabel" Text='<%# "You are defined as translator to " + Eval("LanguageName") %>'></asp:Label>
                    <asp:HiddenField ID="SourceItemIdHiddenField" runat="server" Value='<%# Eval("SourceItem") %>' />
                    <br />
                    <asp:Label ID="TitleLabel" runat="server" Text='<%$ Resources:Resource, Global_Title %>' SkinID="InfoLabel"></asp:Label>
                    <br />
                    <asp:Label ID="EnglishTitleTitleLabel" runat="server" SkinID="InfoLabel" Text="English title:"></asp:Label>
                    <asp:Label ID="EnglishTitleLabel" runat="server" Text='<%# Eval("EnglishTitle") %>' SkinID="GridLabel"></asp:Label>
                    <br /><br />
                    <asp:Label ID="PleaseTranslateTitleTitleLabel" runat="server" SkinID="InfoLabel" Text="Your translation of the title:"></asp:Label>
                    <br />
                    <asp:TextBox ID="TranslatedTitle" runat="server" MaxLength="255" Width="360"></asp:TextBox>
                    <br /><br />
                    <asp:Label ID="NewsMessagetitleLabel" runat="server" Text="<%$ Resources:Resource, AdminAddNews_NewsContentLabel %>" SkinID="InfoLabel"></asp:Label>
                    <br /><br />
                    <asp:Label ID="EnglishTextTitleLabel" runat="server" Text="English text: " SkinID="InfoLabel"></asp:Label>
                    <asp:Label ID="EnglishTextLabel" runat="server" Text='<%# Eval("EnglishText").ToString().Replace("\r\n", "<br /> ").Replace("\n", "<br /> ")  %>' SkinID="GridLabel"></asp:Label>
                    <br /><br />
                    <asp:Label ID="PleaseTranslateTextTitleLabel" runat="server" SkinID="InfoLabel" Text="Your translation of the text:"></asp:Label>
                    <br />
                    <CustomControls:TextArea runat="server" ID="NewsTextArea" MaxLength="3000" TextMode="MultiLine"
                    Height="250px" Width="360px"></CustomControls:TextArea>
                    <asp:Button ID="TranslateButton" runat="server" OnClick="Translate" CssClass="GreenSmallButtonStyle"
                     Text="<%$ Resources:Resource, Global_Submit %>" />
                </ItemTemplate>
                <EmptyDataTemplate>
                    <asp:Label ID="NothingToTranslate" runat="server" SkinID="GridLabel" Text="No news to translate at this stage"></asp:Label>
                </EmptyDataTemplate>
            </asp:FormView>
        </div>
        </div>
        <asp:SqlDataSource ID="TranslateDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
            SelectCommand="Nivdal_GetNewsItemforTranslation" SelectCommandType="StoredProcedure"></asp:SqlDataSource>
    </ContentTemplate>
    </asp:UpdatePanel>
    <br /><br />
    
     
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="PageNamePlaceHolder" runat="server">
    <asp:Label ID="PageNameLabel" runat="server" Text="Nivdal news item translation" CssClass="PageNameContentStyle"></asp:Label>
</asp:Content>
